code
<<
CREATE FUNCTION "requests_insert_after" () RETURNS opaque AS '
DECLAREview_name text;
BEGINview_name := ''request_'' || NEW.id;CREATE VIEW view_name AS select * from groups;return NEW;
END' LANGUAGE 'plpgsql';
CREATE TRIGGER "requests_insert_after" AFTER INSERT ON "requests" FOR EACH ROW
EXECUTE PROCEDURE "requests_insert_after" ();>>
This code after an insertion on table "requests" give me this message :
<<
PostgreSQL said: ERROR: parser: parse error at or near "$1"
>>
Why ?
Thx for any help.
Emmanuel Engelhart